<style>
.content-group {background:#fff;border-radius: 0.5rem;margin-bottom:0.39rem}
.fui-tab-scroll .item.on:before {background:linear-gradient(to right,rgba(99,190,114,1),rgba(99,190,114,0));}
</style>
<div class="fui-page shop-index-page" style="display:block;">
    <div class="fui-content" style="padding-bottom:4rem">
		<div ng-if="pagedata.pluginset.no_hdp!=1" id="carousel-container" class="carousel slide" data-role="carousel" data-param-auto="true">
					<div class="carousel-inner" role="listbox" style="height:6rem">
					<div ng-class="{'item':1,'active':$index==0}" ng-repeat="item in pagedata.banner">						
						<a href="{{item.url}}">
							<img src="{{tomedia(item.picurl) || '../addons/jy_wechatnews/resource/img/hdp01.jpg'}}" style="display: block; width: 100%; height: 100%;">
						</a>
					</div>
					</div>
						<style>
								.fui-swipe-page .fui-swipe-bullet {background: {background}; opacity: {opacity};}
								.fui-swipe-page .fui-swipe-bullet.active {opacity: 1;}
						</style>
						<div id="carousel-jinyun" class="fui-swipe-page" style="padding: 0 5px; bottom: 10px; ">
							<div class="fui-swipe-bullet" ng-repeat="item in pagedata.banner" ng-class="{'active':$index==0}" data-target="#carousel-container" data-slide-to="{{$index}}"></div>
						</div>
		</div>
		<div ng-if="pagedata.notices.length>0 && pagedata.pluginset.no_notice!=1" class="fui-notice">
			<div class="image"><img src="../core/resource/images/diy/hotdot.jpg"></div>
			<div class="icon"><i class="fa fa-volume-up" style="font-size: 0.7rem;"></i></div>
			<div class="text">
				<ul>
						<li ng-repeat="item in pagedata.notices">
							<a href="javascript:;" ng-click="access_json('core/article.list/detail/id='+item.id)">{{item.title}}</a>
						</li>
				</ul>
			</div>
		</div>
		<script type="text/javascript">
			function autoScroll(obj){
				$(obj).find("ul").animate({  
					marginTop : "-1rem"  
				},1000,function(){  
					$(this).css({marginTop : "0px"}).find("li:first").appendTo(this);  
				})  
			}  
			$(function(){  
				setInterval('autoScroll(".fui-notice .text")',3000);
			}) 
		</script>
		<div style="padding:0">
			<div class="fui-cellone" style="margin-top: 0;margin-bottom:0.2rem;background:#fff">
				<div class="fui-cellone-info">
					<div class="search-input" style="height:1.6rem">
						<form action="javascript:return true">
						<i id="searchsub" class="icon icon-sousuo1 bold" ng-click="access_json('jy_wechatnews/list//keyword='+pagedata.params.keyword)" style="line-height: 1.7rem;"></i>
						<input type="search" placeholder="搜索公众号" class="search" ng-model="pagedata.params.keyword" style="height:1.6rem;text-align: left; color: #999; font-size:0.6rem;background:#f2f2f2;border-radius: 1rem;border: 1px solid #f2f2f2;" />
						</form>
					</div>
				 </div>
				 <div class="fui-cell-remark noremark">
					搜索
				</div>
			</div>
			<div ng-if="pagedata.pluginset.bankuai.length>0" class="fui-icon-group noborder col-4 radius">
				<a class="fui-icon-col external" ng-repeat="item in pagedata.pluginset.bankuai" href="javascript:;" ng-click="access_json(item.action)" data-nocache="true">
						<div class="icon">
						<img ng-src="{{tomedia(item.img) || '../core/resource/images/diy/icon/icon_goods.png'}}">
						</div>
						<div class="text">{{item.title}}</div>
				</a>
			</div>
			<div id="containerId"></div>
			<div class="jy-content">
			<div class="fui-cellone" style="padding-bottom:0" href="javascript:;" ng-click="access_json('jy_wechatnews/list/')">
				<div class="fui-cellone-text bold">公众号表</div>
				<div class="fui-cellone-remark" style="font-size: 0.65rem;">查看全部公众号</div>
			</div>
			<div ng-include="sys_html('_list')"></div>
			</div>
			<div ng-if="pagedata.loading" class='infinite-loading'><span class='fui-preloader'></span><span style="margin-left:1.5rem"> 正在加载...</span></div>
			<div ng-include="sys_html('_copyright')"></div>
		</div>
		</div>
</div>
<div ng-include="sys_html('_adjs')"></div>
<div ng-include="sys_html('_footer')"></div>
<script>
require(['bootstrap', 'hammer'], function($, Hammer){
		$('#carousel-container').carousel();
		var mc = new Hammer($('#carousel-container').get(0));
		mc.on("panleft", function(ev) {
			$('#carousel-container').carousel('next');
		});
		mc.on("panright", function(ev) {
			$('#carousel-container').carousel('prev');
		});
});
//手机软键盘--搜索
$("body").keydown(function() {
    if (event.keyCode == "13") {
        $('#searchsub').click();
    }
});
scope.pagedata.scancode=function () {
			console.log('scanQRCodeOK');
			wx.scanQRCode({
				needResult: 1, // 默认为0，扫描结果由微信处理，1则直接返回扫描结果，
				scanType: ["qrCode","barCode"], // 可以指定扫二维码还是一维码，默认二者都有
				success: function (res) {
					var result = res.resultStr; // 当needResult 为 1 时，扫码返回的结果
					result=result.replace('EAN_13,', '');
					scope.pagedata.params.keyword = result;
					scope.$evalAsync();
				}
			});
}
</script>